<?php

class Connection 
{
	var $hostname, $username, $password, $database;
	
	function __construct() 
	{
		$this->hostname= "localhost";
        	$this->username = "root";
        	$this->password = "";
        	$this->database = "autogator_demo";

		/*$this->hostname= "localhost";
        	$this->username = "autogator";
        	$this->password = "autogator";
        	$this->database = "autogator_test";*/

		/*$this->hostname= "localhost";
        	$this->username = "autogator";
        	$this->password = "123456";
        	$this->database = "autogator_demonew";*/

		$this->port = "3306";
		$this->dbConnection(); 
	}
	
	public function dbConnection () 
	{
		$connection = mysql_connect($this->hostname, $this->username, $this->password, $this->port) or die ('Cannot make a connection');
		if ($connection) 
		{
			$selectDB = mysql_select_db($this->database) or die ('Cannot select database');
		}
	}
}
$connect = new Connection();
?>